<!doctype html>
<html>
<head>
<meta charset="utf-8">
</head>
<body>
<button id="btn" onclick="this.style.background='red';">按    钮</button>
<button id="btn" onclick="(event.srcElement?event.srcElement:event.target).style.background='red';">按    钮</button>
</body>
</html>
